NoSQL operator: totaltable

Sums up selected table columns.

Usage: totaltable [options] [column ...]

Options:
    --input (-i) 'file'
      Read input from 'file' instead of STDIN.

    --output (-o) 'file'
      Write output to 'file' instead of STDOUT.

    --help (-h)
      Display this help text.

    --no-header (-N)
      Suppress table header from output.

    --total (-T) 'column'
      The table will be appended an extra column with the
      specified 'column' name, containing the grand-total
      of the columns that were summed.

    --report (-r)
      Print the whole table to STDOUT, along with totals,
      and insert special formatting fields to be interpreted
      by 'justify'.

    --last (-l)
      If the input table contains duplicated column names
      pick the last occurrence of each. The default is to
      pick the first one. This is sometimes useful after
      the 'jointable' operator.

    --currency (-c)
      The specified columns are expected to contain currency
      values, so the output format is set to "%.3f". Although
      currency values are normally rounded to two decimal digits,
      three digits are used by this program, to prevent rounding
      problems that may otherwise occur.

    --trim (-t)
      Remove leading and trailing TABs from output. This is
      useful when all we want is the total value of one
      single column, as with 'totaltable -N -t Column < table'.
      The output is usually no longer a valid NoSQL table.

    --subtotal (-s) 'list'
      Print subtotals of the specified columns whenever the value
      of break columns(s) changes. The 'list' string is a comma-
      separated list of the desired break columns. If the '-s'
      option is specified, it causes 'totaltable' to ignore '-T'
      and to force '-r'.

Notes:

Adds the values in the selected columns and displays them.
If no columns are specified, then nothing is summed.
Back